<template>
  <div>
    <h1>测试组件内守卫</h1>
  </div>
</template>

<script>
export default {
  beforeRouteEnter() {
    console.log("进入了Guard路由");
  },
  beforeRouteUpdate() {
    console.log("更新了guard路由");
  },
  beforeRouteLeave() {
    console.log("即将离开Guard路由");
  },
};
</script>

<style lang="scss" scoped></style>
